﻿//=======================================================
// 作者：KingSley
// 描述：
//=======================================================
using UnityEngine;
using System.Collections;
using UnityEngine.UI;

namespace Singleton
{
    class StartSceneState : ISceneState
    {
        public StartSceneState() : base("StartScene") { }

        public override void StartScene()
        {
            GameObject.FindGameObjectWithTag("Battle").GetComponent<Button>().onClick.AddListener(OnBtnBattle);
            GameObject.FindGameObjectWithTag("MainMenu").GetComponent<Button>().onClick.AddListener(OnBtnMainMenu);
        }

        private void OnBtnBattle()
        {
            SceneStateManager.GetInstacne.SetSceneState(new BattleScene());
        }


        private void OnBtnMainMenu()
        {
            SceneStateManager.GetInstacne.SetSceneState(new MainMenuSceneState());
        }
    }
}